<template>
  <scroll class="item-list">
    <cart-list-item
      v-for="(item, index) in $store.state.cartList"
      :key="index"
      :product="item"
      :index="index"
    >
    </cart-list-item>
  </scroll>
</template>

<script>
// 导入滚动模块
import Scroll from "../../../components/common/scroll/scroll.vue";

// 引入每商品详细组件
import CartListItem from "./CartListItem.vue";

export default {
  name: "CartList",
  components: {
    Scroll,
    CartListItem,
  },
};
</script>

<style scoped>
.item-list {
  height: calc(100% - 93px);
  overflow: hidden;
}
</style>

